﻿using Glorysoft.EAP.Core.Enums;
using System;
using System.Collections.Generic;
using System.Xml.Serialization;

namespace Glorysoft.EAP.EAPClient.Model
{
    [Serializable]
    [XmlRoot("Body")]
    public class Lot
    {
        public Lot()
        {
            LotList = new List<LOT>();
            ContentMap = new List<SLOT>();
            Sampling = new List<SLOT>();
            LOSSINFOLIST = new List<LOSSINFOLIST>();
        }
        public string LotId { get; set; }
        public string CarrierId { get; set; }
        public string LotType { get; set; }
        public Int32 TotalQty { get; set; }
        public string RecipeId { get; set; }
        public string ReticleId { get; set; }
        public string Unloadfiles { get; set; }
        public ProcessState ProcessStatus { get; set; }
        public string Product { get; set; }
        public string ProductVer { get; set; }
        public string ChangeRecipe { get; set; }
        public string CurrentSpec { get; set; }
        public string EqpId { get; set; }
        public string PortId { get; set; }
        public string UserName { get; set; }
        public bool IsPodPlaced { get; set; }
        public string PassWord { get; set; }
        public List<string> Wafers { get; set; }
        public JLStatus LotStatus { get; set; }
        public string StartTime { get; set; }
        public string EndTime { get; set; }
        public ProcessState PreState { get; set; }
        public ControlState EQPState { get; set; }
        public string MoveInTime { get; set; }
        public string MoveOutTime { get; set; }
        public bool IsRFIDReport { get; set; }
        public string SlotMap { get; set; }
        public bool IsScanReport { get; set; }
        public bool PPIDChecked { get; set; }
        public bool RMSChecked { get; set; }
        public string ProcessJobId { get; set; }
        public string ControlJobId { get; set; }
        //站点
        public string OPERATION { get; set; }

        public List<LOSSINFOLIST> LOSSINFOLIST  { get;set;}
        /// <summary>
        /// 用户编号
        /// </summary>
        public string CUSTOMER { get; set; }
        /// <summary>
        /// 机种编号
        /// </summary>
        public string DEVICE { get; set; }
        /// <summary>
        /// 客户批号
        /// </summary>
        public string CUSTOMER_LOT { get; set; }
        /// <summary>
        /// NEEDDETAIL=1再传一个CARRIER会有一个LOTLIST,一个LOTLIST最少有一至多个LOT
        /// </summary>
        public List<LOT> LotList { get; set; }
        /// <summary>
        /// NEEDDETAIL=1再传 一个载具只会有一个CONTENT MAP,CONTENT MAP最少需有一个SLOT信息
        /// </summary>
        public List<SLOT> ContentMap { get; set; }
        /// <summary>
        /// 只有Sampling机台需要,SAMPLING最少需有一笔SLOT
        /// </summary>
        public List<SLOT> Sampling { get; set; }

    }

    [Serializable]
    public class LOT
    {
        /// <summary>
        /// 批号
        /// </summary>
        public string LOTID { get; set; }
        /// <summary>
        /// 一个LOT会有一个WAFERLIST,一个WAFERLIST最少有一至多个WAFER
        /// </summary>
        public List<WAFER> WAFERLIST { get; set; }
    }


    [Serializable]
    public class WAFER
    {
        /// <summary>
        /// WAFER编号
        /// </summary>
        public string WAFERID { get; set; }
    }
    [Serializable]
    public class SLOT
    {
        /// <summary>
        /// SLOT编号
        /// </summary>
        public string SLOTNO { get; set; }
        /// <summary>
        /// WAFER编号
        /// </summary>
        public string WAFERID { get; set; }
        /// <summary>
        /// 打标内容
        /// </summary>
        public string MARKCODE { get; set; }
        /// <summary>
        /// 实物ID
        /// </summary>
        public string ORIGINWAFERID { get; set; }
        /// <summary>
        /// 片子颜色
        /// </summary>
        public string WaferColor { get; set; }


        /// 是否移动过
        /// </summary>
        public string NEWFLAG { get; set; }
        /// <summary>
        /// wafer 要到达的指定位置
        /// </summary>
        public string DESTNO { get; set; }

    }
}

